<template>
  <div class="show">
    <h1>我是App组件我的学校名是:{{school}}</h1>
    <input type="text" ref="keyword">
    <button @click="show">点我提示左侧输入</button>
    <hr>
    <Demo  :xuexiao="school"/>
  </div>
</template>

<script>
import Demo from "./components/Demo";
export default {
  data(){
   return{
      school:'清华'
   }
  },
  components: {
    Demo
  },
  methods:{
    show(){
      alert(this.$refs.keyword.value)
    }
  }
};
</script>

<style>
.show{
  background-color: skyblue;
  padding: 30px;
}
</style>